<%--
  Created by IntelliJ IDEA.
  User: RiceBall
  Date: 2020/7/8
  Time: 10:53
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<html>
<head>
    <title>Title</title>
    <script crossorigin="anonymous" integrity="sha384-LVoNJ6yst/aLxKvxwp6s2GAabqPczfWh6xzm38S/YtjUyZ+3aTKOnD/OJVGYLZDl"
            src="https://lib.baomitu.com/jquery/3.5.0/jquery.min.js"></script>
</head>
<body>

<div style="text-align: center;margin: 0px">
    查询了所有的数据：
    <table style="margin: auto" border="1">
        <tr>
            <td>账号</td>
            <td>姓名</td>
            <td>密码</td>
        </tr>
        <c:forEach var="user" items="${users}">
            <div id="tbody">
                <tr>
                    <td>${user.id}</td>
                    <td>${user.username}</td>
                    <td>${user.password}</td>
                </tr>
            </div>
        </c:forEach>

    </table>
    <c:if test="${pageNum>1}">
        <a href="/user/findAll?pageNum=${pageNum-1}&&pageSize=${pageSize}">上一页</a>
    </c:if>
    <c:if test="${pageNum<totalPage}">
         <a href="/user/findAll?pageNum=${pageNum+1}&&pageSize=${pageSize}">下一页</a>
    </c:if>
    <br>
    第${pageNum}页，总计${totalPage}页，共有${totalSize}条数据，每页${pageSize}条数据
</div>
</body>
</html>
